package net.sk.china.platform.dao.system;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import net.sk.china.platform.model.system.SystemMenu;

import java.util.List;

/**
 * 系统菜单表 Mapper 接口
 * +----------------------------------------------------------------------
 * // | Talk To [ 聊来改善地区金融服务环境，助力企业发展 ]
 * // +----------------------------------------------------------------------
 * // | Copyright (c) 2018-2024 聊来 All rights reserved.
 * // +----------------------------------------------------------------------
 * // | Licensed ( <a href="http://www.apache.org/licenses/LICENSE-2.0">apache</a> )
 * // +----------------------------------------------------------------------
 * // | @Author: 聊来 <18970881148@qq.com>
 * // +----------------------------------------------------------------------
 * // | DateTime: 2024/6/2 16:36
 * // +----------------------------------------------------------------------
 */
public interface SystemMenuDao extends BaseMapper<SystemMenu> {

    /**
     * 通过角色数据获取权限
     * @param userId 用户id
     * @return {@code List<SystemMenu>}
     */
    List<SystemMenu> findPermissionByUserId(Integer userId);


    /**
     * 获取用户路由
     * @param userId 用户id
     * @return {@code List<SystemMenu>}
     */
    List<SystemMenu> getMenusByUserId(Integer userId);
}
